package entities;

import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.HashMap;

import DBside.Tools;

import tables.AbstractEntity;;

public class EntityInCD<T extends AbstractEntity> {
	private T entity;
	private ArrayList<CD> cds;
	
	public EntityInCD(T entity){
		this.entity = entity;
		this.cds = new ArrayList<CD>();
	}
	
	public EntityInCD(T entity, CD cd){
		this.entity = entity;
		this.cds = new ArrayList<CD>();
		this.cds.add(cd);
	}
	
	public AbstractEntity getEntity() {
		return entity;
	}
	
	public ArrayList<CD> getCds() {
		return cds;
	}
	
	public void setEntity(T entity) {
		this.entity = entity;
	}
	
	public void setCds(ArrayList<CD> cds) {
		this.cds = cds;
	}
	
	//******** tools **********\\
	public void addCD(CD cd){
		this.cds.add(cd);
	}
	

	
}





















